<?php
defined("_ALLOW") or die ("Access denied");
?>
<script language="javascript">
var preshow=null;
</script>
<script language="javascript">
function showhidepart(idobj) {
	var obj = document.getElementById(idobj);
	var preobj = null;
	var status = "";
	status = obj.style.display;
	if (preshow != null){
		preobj = document.getElementById(preshow);
		preobj.style.display="none";
		preshow=null;
		
	}
	if (status == ""){
		status = "none";
	}
	else{
		preshow=idobj;
		status = "";
	}
	obj.style.display = status;
}
</script>
<?php
global $array;
include_once("class/cproductcategory.php");
include_once("class/cproduct.php");
global $objproduct;
global $strwhere;
global $lang;
?>
<table width="100%" cellpadding="0" cellspacing="0" style="border-collapse:collapse">
<tr >
<td width="41" height="34" style="background-image:url(images/tieude_mid1.jpg); background-repeat:no-repeat; border-right:#999999 1px solid; font-family:Tahoma; font-size:11px; font-weight:bold; color:#000000; text-align:center;">STT
</td>
<td style="background-color:#95d9ec; font-family:Tahoma; font-size:11px; font-weight:bold; color:#000000; text-align:center; text-transform:uppercase">Thông tin bất động sản</td>
<td width="98" style="background-image:url(images/tieude_mid3.jpg); background-repeat:no-repeat; border-left:#999999 1px solid; font-family:Tahoma; font-size:11px; font-weight:bold; color:#000000; text-align:center; text-transform:uppercase">Ngày đăng</td>
</tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0" border="0" >
<?php
$indexrow = 0;
//$count = count($array);
global $maxRows;
$curPage = 1;
if(isset($_GET['curPage']))
	$curPage = $_GET['curPage'];
$count = $maxRows*($curPage-1);	
foreach ($array as $objproduct) {
	$indexrow = 1- $indexrow;
	$linktour = "index.php?module=com_product&task=view&id=" . $objproduct->id;
	$introtexttour = $objproduct->Get_Intro();
	$introtexttour = str_replace("'","\'",$introtexttour);
	$count +=1;

?>
<?php
$dividfaq = "pro" . $objproduct->id;
?>
<!--onmouseover="this.className='rowhover'" onmouseout="this.className='row'"-->
<tr >
<td style="border-top:1px #999999 solid;" >
<div onMouseOver="location.href='javascript:void(0);'" onclick="showhidepart('<?php echo $dividfaq; ?>'); " style="cursor:pointer;">
	<table width="100%" cellpadding="0" cellspacing="0" border="0" >
		<tr>
			<td height="23" width="41" style="font-family:Tahoma; font-size:11px;  text-align:center; border-bottom:1px #999999 solid;"><?php echo $count;?></td>
			<td style="padding-left:5px; border-left:1px #999999 solid; border-bottom:1px #999999 solid; font-family:Tahoma; font-size:12px; " onmouseover="this.className='rowhover'" onmouseout="this.className='row'" ><?php echo $objproduct->Get_title(); ?></td>
			<td width="98" style="font-family:Tahoma; font-size:11px; font-weight:bold; text-align:center; border-left:1px #999999 solid; border-bottom:1px #999999 solid; "><?php echo substr($objproduct->flastupdate,5,11); ?></td>
		</tr>
	</table>

</div>
		<div id="<?php echo $dividfaq; ?>" style="display:none;">
		<table width="100%" cellpadding="0" cellspacing="0" border="0">
			<tr>
				
				<td colspan="3">
					<?php echo $objproduct->Out_TheHien(90); ?>
				</td>
				
			</tr>
		</table>
		</div>
	
</td>

</tr>
<?php } ?>
</table>